import request from './index';
const fetch = {
    newsType: () => request('news/types', {}, 'GET'),
    newsList: (id, page) =>
        request(`news/list?typeId=${id}&page=${page}`, {}, 'GET'),
    newsDetail: id => request(`news/details?newsId=${id}`, {}, 'GET'),
    getUsers: () => request('users', {}, 'GET')
};

export default fetch;
